import { MongooseFactory } from '../kalend';
import { Schema } from 'mongoose';


const LogSchema = MongooseFactory.Schema({
    path: {
        type: String
    },
    hostname: {
        type: String
    },
    method: {
        type: String
    },
    param: {
        type: Object
    },
    query: {
        type: Object
    },
    reqtime: {
        type: Object
    },
    headers: {
        type: Object
    },
    requestjson: {
        type: Object
    },
    responsejson: {
        type: Schema.Types.Mixed
    }
});

export const requestlogModel = MongooseFactory.Model("loginfo", LogSchema);